﻿<Window
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"        
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" x:Class="MacroprocesosWPF.Administrador.AdminPrincipal"
        Title="Administrador" Height="450" Width="749" WindowStartupLocation="CenterScreen" Loaded="Window_Loaded_1">
    <!--xmlns:AccesoDatos="clr-namespace:Unimaq.Macroprocesos.AccesoDatos;assembly=Unimaq.Macroprocesos.AccesoDatos"-->
    <Window.Resources>
        <!--<Style x:Key="MyFocusVisual">
            <Setter Property="Control.Template">
                <Setter.Value>
                    <ControlTemplate TargetType="{x:Type Control}">
                        <Grid Margin="8">
                            <Ellipse Name="r1" Stroke="Black" StrokeDashArray="2 2" StrokeThickness="1"/>
                            <Border Name="border" Width="{TemplateBinding ActualWidth}" Height="{TemplateBinding ActualHeight}"
                                BorderThickness="1" CornerRadius="2"/>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style x:Key="CircleButton" TargetType="Button">
            <Setter Property="OverridesDefaultStyle" Value="True"/>
            <Setter Property="Margin" Value="2"/>
            <Setter Property="FocusVisualStyle" Value="{StaticResource MyFocusVisual}"/>
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="Button">
                        <Grid>
                            <Ellipse Stroke="#FF2F4160" StrokeThickness="4"/>
                            <Ellipse Margin="1" x:Name="highlightCircle" Fill="#FFF6F7F8" />
                            <ContentPresenter x:Name="content" HorizontalAlignment="Center" VerticalAlignment="Center" TextBlock.Foreground="#FF2F4160" />
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsMouseOver" Value="True">
                                <Setter TargetName="highlightCircle" Property="Fill" Value="#FFF6F7F8" />
                            </Trigger>
                            <Trigger Property="IsPressed" Value="True">
                                <Setter TargetName="highlightCircle" Property="Fill" Value="#FF2F4160" />
                                <Setter TargetName="content" Property="TextBlock.Foreground" Value="#FFF6F7F8" />
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>-->
    </Window.Resources>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="72" />
            <RowDefinition/>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="200"/>
            <ColumnDefinition Width="3" />
            <ColumnDefinition/>
        </Grid.ColumnDefinitions>
        <TreeView x:Name="TreeProcesosUnimaq" Margin="5" Grid.Row="1" SelectedItemChanged="TreeProcesosUnimaq_SelectedItemChanged" PreviewMouseRightButtonDown="TreeProcesosUnimaq_PreviewMouseRightButtonDown">
            <TreeView.Resources>
                <Style TargetType="{x:Type TreeViewItem}">
                    <Setter Property="HeaderTemplate">
                        <Setter.Value>
                            <DataTemplate>
                                <StackPanel Orientation="Horizontal">
                                    <TextBlock Text="{Binding}" Margin="5,0" FontSize="14" ContextMenuOpening="TextBlock_ContextMenuOpening_1">
                                        <TextBlock.ContextMenu>
                                            <ContextMenu>
                                                <MenuItem Header="Agregar" Click="menuItemAgregar_Click"></MenuItem>
                                                <MenuItem Header="Eliminar"></MenuItem>
                                            </ContextMenu>
                                        </TextBlock.ContextMenu>
                                    </TextBlock>
                                </StackPanel>
                            </DataTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>
            </TreeView.Resources>
        </TreeView>
        <GridSplitter Grid.Row="0" Grid.Column="1" Background="#FFF6F7ED" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto" Height="Auto" Grid.RowSpan="2" ResizeDirection="Columns" ></GridSplitter>
        <Grid x:Name="Contenedor" Grid.Column="2" Margin="5" Background="#FFF6F7ED" Grid.RowSpan="2"/>
        <Button x:Name="btnEmpresa" HorizontalAlignment="Left" Margin="9,15,0,0" VerticalAlignment="Top" Width="40" Height="40" Click="btnEmpresa_Click">
            <Button.Template>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Grid>
                        <Ellipse Stroke="#FF2F4160" StrokeThickness="4"/>
                        <Ellipse Margin="1" x:Name="highlightCircle" Fill="#FFF6F7F8" />
                        <ContentPresenter x:Name="content" HorizontalAlignment="Center" VerticalAlignment="Center" TextBlock.Foreground="#FF2F4160" />
                        <Image Name="Normal" Source="../Imagenes/organization.png" Width="25" Height="25"/>
                        <Image Name="Pressed" Source="../Imagenes/organization_pressed.png" Width="25" Height="25" Visibility="Hidden"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="highlightCircle" Property="Fill" Value="#FFF6F7F8" />
                        </Trigger>
                        <Trigger Property="IsPressed" Value="True">
                            <Setter TargetName="highlightCircle" Property="Fill" Value="#FF2F4160" />
                            <Setter TargetName="content" Property="TextBlock.Foreground" Value="#FFF6F7F8" />
                            <Setter TargetName="Normal" Property="Visibility" Value="Hidden" />
                            <Setter TargetName="Pressed" Property="Visibility" Value="Visible" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Button.Template>
        </Button>
        <Button x:Name="btnProceso" HorizontalAlignment="Left" Margin="72,15,0,0" VerticalAlignment="Top"  Width="40" Height="40" Click="btnProceso_Click">
            <Button.Template>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Grid>
                        <Ellipse Stroke="#FF2F4160" StrokeThickness="4"/>
                        <Ellipse Margin="1" x:Name="highlightCircle" Fill="#FFF6F7F8" />
                        <ContentPresenter x:Name="content" HorizontalAlignment="Center" VerticalAlignment="Center" TextBlock.Foreground="#FF2F4160" />
                        <Image Name="Normal" Source="../Imagenes/settings.png" Width="25" Height="25"/>
                        <Image Name="Pressed" Source="../Imagenes/settings_pressed.png" Width="25" Height="25" Visibility="Hidden"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="highlightCircle" Property="Fill" Value="#FFF6F7F8" />
                        </Trigger>
                        <Trigger Property="IsPressed" Value="True">
                            <Setter TargetName="highlightCircle" Property="Fill" Value="#FF2F4160" />
                            <Setter TargetName="content" Property="TextBlock.Foreground" Value="#FFF6F7F8" />
                            <Setter TargetName="Normal" Property="Visibility" Value="Hidden" />
                            <Setter TargetName="Pressed" Property="Visibility" Value="Visible" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Button.Template>
        </Button>
        <Button x:Name="btnDocumento" HorizontalAlignment="Left" Margin="137,15,0,0" VerticalAlignment="Top"  Width="40" Height="40" Click="btnDocumento_Click">
            <Button.Template>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Grid>
                        <Ellipse Stroke="#FF2F4160" StrokeThickness="4"/>
                        <Ellipse Margin="1" x:Name="highlightCircle" Fill="#FFF6F7F8" />
                        <ContentPresenter x:Name="content" HorizontalAlignment="Center" VerticalAlignment="Center" TextBlock.Foreground="#FF2F4160" />
                        <Image Name="Normal" Source="../Imagenes/administrator.png" Width="25" Height="25"/>
                        <Image Name="Pressed" Source="../Imagenes/administrator_pressed.png" Width="25" Height="25" Visibility="Hidden"/>
                    </Grid>      
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="highlightCircle" Property="Fill" Value="#FFF6F7F8" />
                        </Trigger>
                        <Trigger Property="IsPressed" Value="True">
                            <Setter TargetName="highlightCircle" Property="Fill" Value="#FF2F4160" />
                            <Setter TargetName="content" Property="TextBlock.Foreground" Value="#FFF6F7F8" />
                            <Setter TargetName="Normal" Property="Visibility" Value="Hidden" />
                            <Setter TargetName="Pressed" Property="Visibility" Value="Visible" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Button.Template>            
        </Button>
    </Grid>
</Window>
